package org.biz.modules.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.datatype.jsr310.deser.LocalDateDeserializer;
import com.fasterxml.jackson.datatype.jsr310.deser.LocalDateTimeDeserializer;
import com.fasterxml.jackson.datatype.jsr310.ser.LocalDateSerializer;
import com.fasterxml.jackson.datatype.jsr310.ser.LocalDateTimeSerializer;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.biz.common.ExportField;
import org.biz.config.PasswordSerializer;
import org.springframework.format.annotation.DateTimeFormat;

import java.time.LocalDateTime;
import java.util.Date;

/**
 * 用户表
 * @author zf
 * @ClassName SysUser
 */
@Data
@TableName("sys_user")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
public class SysUser {

    @TableId(type = IdType.ASSIGN_ID)
    private String id;
    /** 姓名**/
    @ExportField(name = "姓名",width = 10)
    @ApiModelProperty(value = "姓名")
    private String name;
    /** 身份证号**/
    @ExportField(name = "身份证号",width = 20)
    @ApiModelProperty(value = "身份证号")
    @TableField("id_card")
    private String idCard;
    /** 手机号**/
    @ExportField(name = "手机号",width = 15)
    @ApiModelProperty(value = "手机号")
    private String mobile;
    /** 证书编号**/
    @ExportField(name = "证书编号",width = 10)
    @ApiModelProperty(value = "证书编号")
    @TableField("certificate_num")
    private String certificateNum;
    /** 取得证书时间**/
    @ExportField(name = "取得证书时间",width = 10)
    @ApiModelProperty(value = "取得证书时间")
    @TableField("certificate_date")
    private String certificateDate;
    /** 开班年限**/
    @ExportField(name = "开班年限",width = 10)
    @ApiModelProperty(value = "开班年限")
    @TableField("train_year")
    private String trainYear;
    /** 密码**/
    @ApiModelProperty(value = "密码")
    @JsonSerialize(using = PasswordSerializer.class)
    private String pwd;
    /** 目前所在科室 **/
    @ApiModelProperty(value = "目前所在科室")
    @TableField("current_depart")
    private String currentDepart;
    /** 创建人**/
    @ApiModelProperty(value = "创建人")
    @TableField("create_by")
    private String createBy;
    /** 更新人**/
    @ApiModelProperty(value = "更新人")
    @TableField("update_by")
    private String updateBy;
    /** 创建时间**/
    @ApiModelProperty(value = "创建时间")
    @TableField("create_time")
    @JsonSerialize(using = LocalDateTimeSerializer.class)
    @JsonDeserialize(using= LocalDateTimeDeserializer.class)
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;
    /** 更新时间**/
    @ApiModelProperty(value = "更新时间")
    @TableField("update_time")
    @JsonSerialize(using = LocalDateTimeSerializer.class)
    @JsonDeserialize(using= LocalDateTimeDeserializer.class)
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime updateTime;
    /** 工作医院（单位）**/
    @ExportField(name = "目前工作单位",width = 25)
    @ApiModelProperty(value = "工作医院（单位）")
    private String hospital;
    /** 工作医院（单位）所在城市**/
    @ExportField(name = "目前城市",width = 10)
    @ApiModelProperty(value = "工作医院（单位）所在城市")
    @TableField("hospital_city")
    private String hospitalCity;
    /** 培训基地**/
    @ExportField(name = "培训基地",width = 25)
    @ApiModelProperty(value = "培训基地")
    @TableField("base_hospital")
    private String baseHospital;
    /** 所属专科**/
    @ExportField(name = "所属专科",width = 15)
    @ApiModelProperty(value = "所属专科")
    private String department;
    /** 职务**/
    @ExportField(name = "职务",width = 10)
    @ApiModelProperty(value = "职务")
    private String duty;
    /** 头像**/
    @ApiModelProperty(value = "头像")
    @TableField(updateStrategy = FieldStrategy.IGNORED)
    private String avatar;
    /** 证书**/
    @ApiModelProperty(value = "证书")
    @TableField(updateStrategy = FieldStrategy.IGNORED)
    private String certificate;
    /** 审核状态：未完成，待审核，审核通过，未通过**/
    @ExportField(name = "状态",width = 10)
    @ApiModelProperty(value = "审核状态：未完成，待审核，审核通过，未通过")
    private String status;

    /** 数据（填报）年份**/
    @TableField("data_year")
    @ApiModelProperty(value = "数据（填报）年份")
    private String dataYear;

    /** 认证有效期**/
    @ExportField(name = "认证有效期",width = 15)
    @ApiModelProperty(value = "认证有效期")
    private Integer expire;

    /** 承诺书**/
    @ApiModelProperty(value = "承诺书")
    @TableField(updateStrategy = FieldStrategy.IGNORED)
    private String promise;

    /** 汇总表**/
    @ApiModelProperty(value = "汇总表")
    @TableField(updateStrategy = FieldStrategy.IGNORED)
    private String summary;

    /** 已完成专业课程数**/
    @ExportField(name = "已完成专业课程数",width = 15)
    @ApiModelProperty(value = "已完成专业课程数")
    @TableField(exist = false)
    private int passed;
    /** 学习进度**/
    @ExportField(name = "学习进度",width = 10)
    @ApiModelProperty(value = "学习进度")
    @TableField(exist = false)
    private String progress;


    /** 性别**/
    @ExportField(name = "性别",width = 5)
    @ApiModelProperty(value = "性别")
    private String sex;
    /** 年龄**/
    @ExportField(name = "年龄",width = 5)
    @ApiModelProperty(value = "年龄")
    private Integer age;
    /** 江苏省护理学会会员编号**/
    @ExportField(name = "江苏省护理学会会员编号",width = 20)
    @ApiModelProperty(value = "江苏省护理学会会员编号")
    @TableField("vip_num")
    private String vipNum;
    /** 职称**/
    @ExportField(name = "职称",width = 12)
    @ApiModelProperty(value = "职称")
    private String title;
    /** 学历**/
    @ExportField(name = "学历",width = 12)
    @ApiModelProperty(value = "学历")
    @TableField("education_level")
    private String educationLevel;
    /** 学位**/
    @ExportField(name = "学位",width = 12)
    @ApiModelProperty(value = "学位")
    private String degree;
    /** 岗位**/
    @ExportField(name = "岗位",width = 12)
    @ApiModelProperty(value = "岗位")
    private String station;
    /** 用户级别**/
    @ExportField(name = "用户级别",width = 10)
    @ApiModelProperty(value = "用户级别")
    private String level;


    /** 取证时的工作医院（单位）**/
    @ExportField(name = "取证时工作单位",width = 25)
    @ApiModelProperty(value = "取证时的工作医院（单位）")
    @TableField("hospital_history")
    private String hospitalHistory;
    /** 工作医院（单位）所在城市**/
    @ExportField(name = "取证城市",width = 10)
    @ApiModelProperty(value = "取证时的工作医院（单位）所在城市")
    @TableField("hospital_city_history")
    private String hospitalCityHistory;
    /** 取证时的职务**/
    @ExportField(name = "取证时的职务",width = 12)
    @ApiModelProperty(value = "取证时的职务")
    @TableField("duty_history")
    private String dutyHistory;
    /** 取证时的职称**/
    @ExportField(name = "取证时的职称",width = 12)
    @ApiModelProperty(value = "取证时的职称")
    @TableField("title_history")
    private String titleHistory;
    /** 取证时的学历**/
    @ExportField(name = "取证时的学历",width = 12)
    @ApiModelProperty(value = "取证时的学历")
    @TableField("education_level_history")
    private String educationLevelHistory;
    /** 取证时的学位**/
    @ExportField(name = "取证时的学位",width = 12)
    @ApiModelProperty(value = "取证时的学位")
    @TableField("degree_history")
    private String degreeHistory;
    /** 取证时的岗位**/
    @ExportField(name = "取证时的岗位",width = 12)
    @ApiModelProperty(value = "取证时的岗位")
    @TableField("station_history")
    private String stationHistory;

    @ApiModelProperty(value = "退回标识")
    private String back;

    @ApiModelProperty(value = "证书实际生成日期")
    @TableField("certificate_create_date")
    private String certificateCreateDate;

    @ApiModelProperty(value = "配置证书生成日期")
    @TableField("certificate_date_config")
    private String certificateDateConfig;

    @ExportField(name = "1.1\n" +
            "近5年在专科护士所属专科领域岗位工作，从事临床一线护理或管理工作；",width = 15)
    @TableField(exist = false)
    private String doc1_1;
    @ExportField(name = "1.2\n" +
            "组织开展或掌握本专科领域最新护理技术，提供近5年内 $$ 份有相关护理技术记录的护理病历或相关资料（护理管理者可提供5份业务查房护理记录）；",width = 15)
    @TableField(exist = false)
    private String doc1_2;

    @ExportField(name = "1.3\n" +
            "主持或组织专科护理查房，近5年每年 $$ 次；",width = 15)
    @TableField(exist = false)
    private String doc1_3;

    @ExportField(name = "1.4\n" +
            "组织或参与本专业危重患者的抢救护理，近5年每年 $$ 例；",width = 15)
    @TableField(exist = false)
    private String doc1_4;
    @ExportField(name = "1.5\n" +
            "主持或参与疑难病例讨论，近5年每年 $$ 次；",width = 15)
    @TableField(exist = false)
    private String doc1_5;
    @ExportField(name = "1.6\n" +
            "参与院内外护理会诊，近5年每年 $$ 例；",width = 15)
    @TableField(exist = false)
    private String doc1_6;
    @ExportField(name = "1.7\n" +
            "开设护理门诊，近5年门诊量每年 $$ 例；",width = 15)
    @TableField(exist = false)
    private String doc1_7;


    @ExportField(name = "2.1\n" +
            "近5年参与临床带教或承担医学院校教学工作；",width = 15)
    @TableField(exist = false)
    private String doc2_1;
    @ExportField(name = "2.2\n" +
            "近5年参与省、市级专科护士的带教或者参与授课；",width = 15)
    @TableField(exist = false)
    private String doc2_2;

    @ExportField(name = "2.3\n" +
            "开展本专业新技术、新业务的培训与考核，近5年共开展 $$ 次；",width = 15)
    @TableField(exist = false)
    private String doc2_3;

    @ExportField(name = "2.4\n" +
            "参与本专业面向社会层面的健康教育与科普宣传活动，近5年参与 $$ 次；",width = 15)
    @TableField(exist = false)
    private String doc2_4;
    @ExportField(name = "2.5\n" +
            "近5年内获批院级（排名第一）及以上（排名前三）新技术、新项目 $$ 项；",width = 15)
    @TableField(exist = false)
    private String doc2_5;
    @ExportField(name = "2.6\n" +
            "近5年获得院级（排名第一）及以上（排名前三）护理科研立项或者教学成果 $$ 项；",width = 15)
    @TableField(exist = false)
    private String doc2_6;
    @ExportField(name = "2.7\n" +
            "近5年获得实用新型实用专利或者发明专利 $$ 项（排名第一）；",width = 15)
    @TableField(exist = false)
    private String doc2_7;
    @ExportField(name = "2.8\n" +
            "近5年内以第一作者或者通讯作者（不含共一作者）发表本专业统计源期刊论文 $$ 篇；",width = 15)
    @TableField(exist = false)
    private String doc2_8;

    @ExportField(name = "3.1\n" +
            "参与科室管理相关制度、流程、应急预案的制定、修订或者审核，近5年内共 $$ 项；",width = 15)
    @TableField(exist = false)
    private String doc3_1;
    @ExportField(name = "3.2\n" +
            "运用管理工具主持完成本专业持续质量改进项目，近5年内共 $$ 项；",width = 15)
    @TableField(exist = false)
    private String doc3_2;

    @ExportField(name = "3.3\n" +
            "指导或参与科室的质量控制，提出可行性建议并被采纳，近5年内每年不少于 $$ 条；",width = 15)
    @TableField(exist = false)
    private String doc3_3;
    @ExportField(name = "4.2\n" +
            "近5年内每年参加专业领域内的学术继续教育培训或本专业省级及以上专委会学术会议不少于 $$ 次；",width = 15)
    @TableField(exist = false)
    private String doc4_2;

}
